OUT := main

SRCS := $(wildcard *.c)
OBJS := $(patsubst %.c, %.o,  $(SRCS))

CC := gcc
G := -g -Wall

$(OUT): $(OBJS)
	$(CC) $^ -o $@ $(G)

%.o: %.c
	gcc -c $< -o $@

.PHONY: clean
clean:
	$(RM) $(OBJS) $(OUT)
